package com.yc.star.entity;

import com.baomidou.mybatisplus.annotation.*;
import lombok.Data;

import java.io.Serializable;
import java.time.LocalDateTime;
import java.util.List;

/**
 * <p>
 * 用户
 * </p>
 *
 * @author ljl
 * @since 2024-07-15
 */
@TableName("s_user")
@Data
public class User implements Serializable {

    private static final long serialVersionUID = 1L;

      /**
     * 用户昵称
     */
      private String username;

      /**
     * id
     */
        @TableId(value = "id", type = IdType.AUTO)
      private Long id;

      /**
     * 账号
     */
      private String userAccount;

      /**
     * 用户头像
     */
      private String avatarUrl;

      /**
     * 性别 0男,1女
     */
      private Byte gender;

      /**
     * 密码
     */
      private String password;

      /**
     * 电话
     */
      private String phone;

      /**
     * 邮箱
     */
      private String email;

      /**
     * 状态 0 - 正常
     */
      private Integer userStatus;

      /**
     * 创建时间
     */
      private LocalDateTime createTime;

    private LocalDateTime updateTime;

      /**
     * 是否删除
     */
      @TableLogic
      private Byte isDelete;

      /**
     * 用户角色 0 - 普通用户 1 - 管理员
     */
      private Integer userRole;

      /**
     * 星球编号
     */
      private String planetCode;

      /**
     * 标签 json 列表
     */
      private String tags;

      /**
     * 用户个人相册
     */
      private String imgs;

      /**
     * 个性签名
     */
      private String sign;

      /**
     * 生日
     */
      private LocalDateTime birthday;

    /**
     * 匹配用户的列表
     */
    @TableField(exist = false)
    private List<User> matchUsers;

    /**
     * 点赞数
     */
    @TableField(exist = false)
    private Integer like;

    /**
     * 好友列表
     */
    @TableField(exist = false)
    private List<User> friends;

    /**
     * 队伍列表(包括自己创建的和加入的)
     */
    @TableField(exist = false)
    private List<Team> teams;



    
    public String getUsername() {
        return username;
    }

      public void setUsername(String username) {
          this.username = username;
      }
    
    public Long getId() {
        return id;
    }

      public void setId(Long id) {
          this.id = id;
      }
    
    public String getUserAccount() {
        return userAccount;
    }

      public void setUserAccount(String userAccount) {
          this.userAccount = userAccount;
      }
    
    public String getAvatarUrl() {
        return avatarUrl;
    }

      public void setAvatarUrl(String avatarUrl) {
          this.avatarUrl = avatarUrl;
      }
    
    public Byte getGender() {
        return gender;
    }

      public void setGender(Byte gender) {
          this.gender = gender;
      }
    
    public String getPassword() {
        return password;
    }

      public void setPassword(String password) {
          this.password = password;
      }
    
    public String getPhone() {
        return phone;
    }

      public void setPhone(String phone) {
          this.phone = phone;
      }
    
    public String getEmail() {
        return email;
    }

      public void setEmail(String email) {
          this.email = email;
      }
    
    public Integer getUserStatus() {
        return userStatus;
    }

      public void setUserStatus(Integer userStatus) {
          this.userStatus = userStatus;
      }
    
    public LocalDateTime getCreateTime() {
        return createTime;
    }

      public void setCreateTime(LocalDateTime createTime) {
          this.createTime = createTime;
      }
    
    public LocalDateTime getUpdateTime() {
        return updateTime;
    }

      public void setUpdateTime(LocalDateTime updateTime) {
          this.updateTime = updateTime;
      }
    
    public Byte getIsDelete() {
        return isDelete;
    }

      public void setIsDelete(Byte isDelete) {
          this.isDelete = isDelete;
      }
    
    public Integer getUserRole() {
        return userRole;
    }

      public void setUserRole(Integer userRole) {
          this.userRole = userRole;
      }
    
    public String getPlanetCode() {
        return planetCode;
    }

      public void setPlanetCode(String planetCode) {
          this.planetCode = planetCode;
      }
    
    public String getTags() {
        return tags;
    }
      public void setTags(String tags) {
          this.tags = tags;
      }
    public String getImgs() {
        return imgs;
    }

      public void setImgs(String imgs) {
          this.imgs = imgs;
      }
    
    public String getSign() {
        return sign;
    }

      public void setSign(String sign) {
          this.sign = sign;
      }
    
    public LocalDateTime getBirthday() {
        return birthday;
    }

      public void setBirthday(LocalDateTime birthday) {
          this.birthday = birthday;
      }

    @Override
    public String toString() {
        return "User{" +
              "username = " + username +
                  ", id = " + id +
                  ", userAccount = " + userAccount +
                  ", avatarUrl = " + avatarUrl +
                  ", gender = " + gender +
                  ", password = " + password +
                  ", phone = " + phone +
                  ", email = " + email +
                  ", userStatus = " + userStatus +
                  ", createTime = " + createTime +
                  ", updateTime = " + updateTime +
                  ", isDelete = " + isDelete +
                  ", userRole = " + userRole +
                  ", planetCode = " + planetCode +
                  ", tags = " + tags +
                  ", imgs = " + imgs +
                  ", sign = " + sign +
                  ", birthday = " + birthday +
              "}";
    }
}
